home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part2 / 11028 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  26 lines

  1. Newsgroups: comp.lang.c
  2. Path: axcdf1.pd.infn.it!LORETI
  3. From: loreti@axcdf1.pd.infn.it (Maurizio Loreti)
  4. Subject: Re: Determining the length of an int in string form
  5. X-Nntp-Posting-Host: axcdf1.pd.infn.it
  6. Message-ID: <DoMKJ9.Kn9@news.cern.ch>
  7. Sender: news@news.cern.ch (USENET News System)
  8. Reply-To: loreti@axcdf1.pd.infn.it
  9. Organization: I.N.F.N. Padova - CDF/CMS VAXcluster
  10. References: <3146D058.DD7@cbm.com> <4i7uth$qph@inet-nntp-gw-1.us.oracle.com>,<DoE38u.GIH@iquest.net>
  11. Date: Thu, 21 Mar 1996 16:01:54 GMT
  12.  
  13. In article <DoE38u.GIH@iquest.net>, dlmiller@iquest.net (Doug & Rose Miller) writes:
  14. >Even a 32-bit int is only 9 characters at most, and that's *with* the sign.  Why not just declare
  15. >a string and be done with it?  Is storage space that tight for you, that nine bytes matters?
  16.  
  17. Who said that an integer has at most 32 bits?  Why not 64, as I have?
  18. Or more?
  19.  
  20. However, the solution is to fprintf the integer to the bit bucket
  21. (i.e. /dev/null, NLA0:, NIL or what is called on your system) and to
  22. use its return value.
  23. --
  24. Maurizio Loreti                       http://mvxpd5.pd.infn.it/wwwcdf/mlo.html
  25. Un. of Padova, Dept. of Physics - Padova, Italy          loreti@padova.infn.it
  26.